package com.zswl.decorate.ui;

import android.view.View;

import com.zswl.decorate.R;
import com.zswl.decorate.adapter.ShouYAdapter;
import com.zswl.decorate.base.BaseListActivity;
import com.zswl.decorate.base.HttpResult;
import com.zswl.decorate.bean.ShouYBean;

import java.util.List;

import butterknife.OnClick;
import io.reactivex.Observable;

public class MainActivity extends BaseListActivity<ShouYBean, ShouYAdapter> implements View.OnClickListener {

    @Override
    protected int getLayoutId() {
        return R.layout.activity_main;
    }


    @Override
    protected int getItemLayout() {
        return R.layout.item_shouy_layout;
    }

    @Override
    protected Observable<HttpResult<List<ShouYBean>>> getApi(int page) {
        return api.allCiShanShouYi(page, limit);
    }

    @Override
    public void onClick(View v) {
//        FlutterDemoActivity.startMe(context);
        PagerActivity.startMe(context);
    }

    @OnClick({R.id.tv_connect, R.id.tv_send, R.id.tv_close})
    public void click(View view) {
        switch (view.getId()) {
            case R.id.tv_connect:
                connnet();
                break;
            case R.id.tv_send:

                break;
            case R.id.tv_close:

                break;
        }
    }

    private void connnet() {


    }


}
